package meterMonitor.biz;

import meterMonitor.mapper.MonitorDayMapper;
import meterMonitor.mapper.MonitorMonthMapper;
import meterMonitor.model.MonitorDay;
import meterMonitor.model.MonitorMonth;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class MonitorMonthBiz {
    public static final Logger logger = LoggerFactory.getLogger(MonitorMonthBiz.class);
    @Autowired
    private MonitorMonthMapper monitorMonthMapper;


    public List<MonitorMonth> queryData(String fromTime, String toTime, String codes) {
        return monitorMonthMapper.queryData(fromTime,toTime,codes);
    }

    //月报
    public List<MonitorMonth> queryDataByMonth(String fromTime,String tiTime,String areaId,int deviceTypeCode,String codes){
        return monitorMonthMapper.queryDataByMonth(fromTime, tiTime, areaId, deviceTypeCode, codes);
    }

    public List<MonitorMonth> queryDataByType(String fromTime,String toTime,String codes,int type){
        return monitorMonthMapper.queryDataByType(fromTime, toTime, codes, type);
    }

    public MonitorMonth getCurrentByMeterCode(Long meterCode) {
        return monitorMonthMapper.getCurrentByMeterCode(meterCode);
    }
}

